package com.homework.Demo6_10;

public class JiSuan {
    public int add(int a,int b){

        return a+b;
    }
    public int add(int a,int b,int c){

        return a+b+c;
    }
    public Double add(double a, double b){

        return a+b;
    }
    public Double add(double a, double b,double c){

        return a+b+c;
    }
    public static void main(String args[] ){
        JiSuan test = new JiSuan();
        System.out.println("两个INT类型相加：2,3");
        System.out.println(test.add(2,3));

        System.out.println("三个INT类型相加：2,3,4");
        System.out.println(test.add(2,3,4));

        System.out.println("两个Double类型相加：12.3,5.6");
        System.out.println(test.add(12.3,5.6));

        System.out.println("三个Double类型相加：1.52,3.66,6.99");
        System.out.println(test.add(1.52,3.66,6.99));

    }
}
